package gui;

import java.awt.Color;
import java.awt.Font;

import javax.swing.Icon;
import javax.swing.ImageIcon;
import javax.swing.JLabel;
import javax.swing.JPanel;
import javax.swing.SwingConstants;
import javax.swing.JButton;
import java.awt.event.ActionListener;

/**
 * 
 * @author chkr1_000 initiates AdminMenu class
 * 
 */
public class AdminMenu extends JPanel {

	private JLabel lblAdmin;
	private JLabel lblThebank;
	private JLabel lblCopyright;
	private JButton btnAddAccount2;
	private JButton btnDeleteUserMenu;
	Screen screen;
	private JButton btnLogOutAdmin;

	/**
	 * Create the layout for AdminMenu
	 */
	public AdminMenu() {
		setLayout(null);
		setSize(Screen.SIZE);
		setBackground(Screen.COLOR);

		lblAdmin = new JLabel(".:Admin:.");
		lblAdmin.setForeground(Color.WHITE);
		lblAdmin.setFont(new Font("Helvetica", Font.BOLD, 20));
		lblAdmin.setBounds(281, 50, 88, 21);
		add(lblAdmin);

		lblCopyright = new JLabel("\u00A9 Copyright - All rights reserved");
		lblCopyright.setForeground(Color.WHITE);
		lblCopyright.setFont(new Font("Lucida Grande", Font.PLAIN, 13));
		lblCopyright.setBounds(414, 600, 208, 16);
		add(lblCopyright);

		Icon logo = new ImageIcon(getClass().getResource("190-bank.png"));

		lblThebank = new JLabel("TheBank", logo, SwingConstants.LEFT);
		lblThebank.setForeground(Color.WHITE);
		lblThebank.setFont(new Font("Helvetica", Font.BOLD, 16));
		lblThebank.setBounds(30, 25, 99, 22);
		add(lblThebank);

		btnAddAccount2 = new JButton("Add User");
		btnAddAccount2.setBounds(270, 254, 117, 29);
		add(btnAddAccount2);

		btnDeleteUserMenu = new JButton("Delete User");
		btnDeleteUserMenu.setBounds(270, 338, 117, 29);
		add(btnDeleteUserMenu);

		btnLogOutAdmin = new JButton("Log out");
		btnLogOutAdmin.setBounds(270, 423, 117, 28);
		add(btnLogOutAdmin);

	}

	/**
	 * 
	 * @param addActionListener
	 *            (1)
	 */
	public void addActionListener(ActionListener l) {
		btnAddAccount2.addActionListener(l);
		btnLogOutAdmin.addActionListener(l);
		btnDeleteUserMenu.addActionListener(l);

	}

	/**
	 * 
	 * @return btnLogOutAdmin
	 */
	public JButton getBtnLogOut() {
		return btnLogOutAdmin;
	}

	/**
	 * 
	 * @param btnLogOut
	 */
	public void setBtnLogOut(JButton btnLogOut) {
		this.btnLogOutAdmin = btnLogOut;
	}

	/**
	 * 
	 * @return btnAddAccount2
	 */
	public JButton getBtnAddAccount2() {
		return btnAddAccount2;
	}

	/**
	 * 
	 * @param btnAddccount2
	 */
	public void setBtnAddAccount2(JButton btnAddccount2) {
		this.btnAddAccount2 = btnAddccount2;
	}

	/**
	 * 
	 * @return btnDeleteUserMenu
	 */
	public JButton getBtnDeleteUserMenu() {
		return btnDeleteUserMenu;
	}

	/**
	 * 
	 * @param btnDeleteUserMenu
	 */
	public void setBtnDeleteUserMenu(JButton btnDeleteUserMenu) {
		this.btnDeleteUserMenu = btnDeleteUserMenu;
	}

	/**
	 * 
	 * @return screen
	 */
	public Screen getScreen() {
		return screen;
	}

	/**
	 * 
	 * @param screen
	 */
	public void setScreen(Screen screen) {
		this.screen = screen;
	}

}
